package com.alibaba.dingtalk.openapi.newmessage.entity;/*/*/

import com.alibaba.fastjson.annotation.JSONField;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;

/**
 * 语音消息
 * @author 魏荣杰
 * @date 2019/3/21 15:55
 * @since v1.0
 * @version v1.0
 */
@Setter
@Getter
@ToString
public class Voice extends AbstractMessage{
    private static final long serialVersionUID = -8349853831110657435L;

    /**
     * 	正整数，小于60，表示音频时长
     */
    private String duration;

    /**
     * 	媒体文件id。2MB，播放长度不超过60s，AMR格式
     */
    @JSONField(name = "media_id")
    private String mediaId;

    @Override
    public String type() {
        return "voice";
    }
}
